#include "Dequeuer.h"

Dequeuer::Dequeuer( const std::string& file, const char key ) {
	this->cola = new Message_Queue<messageQueue>( file, key );
}

Dequeuer :: ~Dequeuer() {
}

int Dequeuer::dequeue(const int type) {
	this->cola->read_msg( type ,&(this->msg) );
	return 0;
}

messageQueue Dequeuer::get_message() {
	return this->msg;
}

void Dequeuer::cerrar(){
	this->cola->destroy();
	delete this->cola;
}
